package com.cbgolf.oa.presenter;

import com.cbgolf.oa.contract.IListStatisticsContract.IListStatisticsModel;
import com.cbgolf.oa.contract.IListStatisticsContract.IListStatisticsPresenter;
import com.cbgolf.oa.contract.IListStatisticsContract.IListStatisticsView;
import com.cbgolf.oa.entity.StatisticsBean;
import com.cbgolf.oa.model.ListStatisticsModelImp;

/**
 * @author lq
 */
public class ListStatisticsPresenterImp implements IListStatisticsPresenter {

  private IListStatisticsView view;
  private IListStatisticsModel model;

  public ListStatisticsPresenterImp(IListStatisticsView view) {
    this.view = view;
    this.model = new ListStatisticsModelImp();
  }

  @Override
  public void requestData(int dataType, StatisticsBean data, int requestEvent) {
    view.showProgress();
    model.requestData(dataType, data, requestEvent);
  }

  @Override
  public void filterCaddieData(String level, StatisticsBean data, int requestEvent) {
    view.showProgress();
    model.filterCaddieData(level, data, requestEvent);
  }

}
